home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
FishMarket 1.0
/
FishMarket v1.0.iso
/
fishies
/
301-325
/
disk_319
/
cnewssrc
/
cnews.src.lzh
/
libfake
/
strrchr.c
< prev
next >
Wrap
C/C++ Source or Header
|
1980-01-01
|
395b
|
23 lines
/*
* strrchr - find last occurrence of a character in a string
*/
#define NULL 0
char * /* found char, or NULL if none */
strrchr(s, charwanted)
char *s;
register char charwanted;
{
register char *scan;
register char *place;
place = NULL;
for (scan = s; *scan != '\0'; scan++)
if (*scan == charwanted)
place = scan;
if (charwanted == '\0')
return(scan);
return(place);
}